package com.lfy.domain.entity;

import com.lfy.domain.group.CreateTaskGroup;
import com.lfy.domain.group.ModifyTaskGroup;
import lombok.Data;

import javax.validation.constraints.NotBlank;

/**
 * 任务入参
 *
 * @author <a href="https://www.lvfeiy.top">吕飞扬</a>
 * @date 2024/4/19 12:41
 */
@Data
public class JobDTO {
    @NotBlank(message = "任务名称不能为空",groups = {CreateTaskGroup.class, ModifyTaskGroup.class})
    private String jobName;
    @NotBlank(message = "任务类路径不能为空",groups = {CreateTaskGroup.class})
    private String jobClass;
    private String jobGroup = "DEFAULT";
    /**
     * 不传立即执行，传值则按cron表达式执行
     */
    private String cronExpression;


}
